TARGET ?= default_demo

$(TARGET):led.s
	arm-linux-gnueabihf-gcc -g -c led.s -o $(TARGET).o
	arm-linux-gnueabihf-ld -Ttext 0X87800000 $(TARGET).o -o $(TARGET).elf
	arm-linux-gnueabihf-objcopy -O binary -S -g $(TARGET).elf $(TARGET).bin
	arm-linux-gnueabihf-objdump -D $(TARGET).elf > $(TARGET).dis
	
.PHONY: clean
clean:
	rm -rf *.o  *.imx $(TARGET).bin $(TARGET).elf $(TARGET).dis